// TEST.java
import java.util.ArrayList;
import java.util.List;

public class TEST {
    private double income;
    private double expense;
    private List<String> bills = new ArrayList<>();

    public void recordIncome(double amount) {
        income += amount;
        bills.add("收入：" + amount);
        System.out.println("收入记录成功：" + amount);
    }

    public void recordExpense(double amount) {
        expense += amount;
        bills.add("支出：" + amount);
        System.out.println("支出记录成功：" + amount);
    }

    public void displayBalance() {
        System.out.println("当前余额：" + (income - expense));
    }

    public void displayAllBills() {
        for (String bill : bills) {
            System.out.println(bill);
        }
    }

    public static void main(String[] args) {
        FinanceManager manager = new FinanceManager();
        manager.recordIncome(5000);
        manager.recordExpense(1500);
        manager.displayBalance();
        manager.displayAllBills();
    }
}
